package homework.test3;

public class Recursion {
    public static void main(String[] args) {
        int result = recursion(5);

        System.out.println(result);
    }

    public static int recursion(int num){
        if(num == 1){
            return 1;
        }else {
            return num * recursion(num-1);
        }
    }
}
